import request from '/@/utils/request';

const evaPath = '/eva';

// 查询量因子列表
export function listFactor(query: object) {
  return request({
    url: evaPath + '/factor/page',
    method: 'get',
    params: query
  })
}

// 查询量因子详细
export function getFactor(id: string) {
  return request({
    url: evaPath + '/factor/' + id,
    method: 'get'
  })
}

// 新增量因子
export function addFactor(data: object) {
  return request({
    url: evaPath + '/factor',
    method: 'post',
    data: data
  })
}

// 修改量因子
export function updateFactor(data: object) {
  return request({
    url: evaPath + '/factor',
    method: 'put',
    data: data
  })
}

// 删除量因子
export function delFactor(id: string) {
  return request({
    url: evaPath + '/factor/' + id,
    method: 'delete'
  })
}
